-
Notifications
You must be signed in to change notification settings - Fork 5.3k
[wasm][debugger] Avoid using Uint8Array to set memory content #60087
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
But I'm not using Uint8Array to set the content on memory allocated using malloc as @lewing suggested in the same PR.
|
Tagging subscribers to this area: @thaystg |
|
Tagging subscribers to 'arch-wasm': @lewing |
kg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine, and you can do the single malloc like before if you want
| } | ||
|
|
||
| [Fact] | ||
| public async Task MallocUntilReallocate() //https://github.com/xamarin/xamarin-android/issues/6161 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Should this maybe pause/inspect/resume through one breakpoint first, then call
malloc_to_reallocate_test, and then try the breakpoint again? - Can we add something in the test to confirm that the memory grew?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Why it would be good to test a breakpoint first? I think it's not necessary, if I remove the fix on [wasm][debugger] Fix reusing buffer for debugger #59773, I can perfectly reproduce the behavior that we were getting when debugging from VS.
- I'm not sure, I'll try to find a way to detect it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Why it would be good to test a breakpoint first?
I was thinking that it would ensure that the debugger buffer had been used at least once. But that would get used to even get started with debugging, IIUC, so you are correct - this isn't needed 👍
- I'm not sure, I'll try to find a way to detect it.
Maybe even a simple - UInt8Array before the growth, and then checking that it got reset?
lewing
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine, see comments
Creating a test case for PR #59773
But I'm not using Uint8Array to set the content on memory allocated using malloc as @lewing suggested in the same PR.